import httpInstance from "@/utils/http";

/**
 * 
 * 获取面包屑导航数据
 * @param {*} id 
 * @returns {*}
 */
export function getCategorySub (id:string | string[]) {
  return httpInstance({
    url:'/category/sub/filter',
    params:{
      id
    }
  })
}

/**
 * 获取二级商品列表数据
 * @data { 
    categoryId: 1005000 ,
    page: 1,
    pageSize: 20,
    sortField: 'publishTime' | 'orderNum' | 'evaluateNum'
  } 
 */
export function getCategoryList (data:any) {
  return httpInstance({
    url:'/category/goods/temporary',
    method: 'post',
    data
  })
}